from django.db import models

# Create your models here.

from django.contrib.auth.models import AbstractUser

# 创建,用户模型,继承,系统自带的用户模型,并且创建一个用户模型类中没有的字段
class User(AbstractUser):
    mobile = models.CharField(max_length=11,unique=True,verbose_name='手机号')

    # 设置字段选项
    class Meta:
        db_table = 'tb_users'
        verbose_name = '用户'
        verbose_name_plural = verbose_name